export default {
    install(Vue) {
        Vue.prototype.$tip = {
            Box,
            Message
        }

        function Box(title, content, callback) {
            if (!callback) {
                callback = function () {
                }
            }
            Vue.prototype.$alert(content, title, {
                confirmButtonText: '确定',
                callback: callback
            })
        }

        function Message(content, type) {
            if (!type) {
                type = 'info'
            }
            Vue.prototype.$message({
                message: content,
                type: type
            })
        }

    }
}
